<%@ page language="java" pageEncoding="UTF-8"%>

<div ng-controller="DongtanIndexController">

	<ul class="nav nav-tabs">
		<li class="active">
			<a href="#new" data-toggle="tab">最新动弹</a>
		</li>
		<li>
			<a href="#hot" data-toggle="tab">最热动弹</a>
		</li>
		<li class="pull-right">
			<a href="#/dongtan">更多动弹 > </a>
		</li>
	</ul>
	<br/>
	
	<div class="tab-content">
	
		<div class="tab-pane active" id="new" time="10000" func="upToDate()" interval>
			<div class="message-wrap">
				<br/>
				<div class="msg-wrap" ng-repeat="dongtan in newDongtans.data">
					<include path="/dongtan_layout.html"></include>
					<hr />
				</div>
			</div>
		</div>
		
		<div class="tab-pane" id="hot">
			<div class="message-wrap">
				<br/>
				<div class="msg-wrap" ng-repeat="dongtan in hotDongtans.data">
					<include path="/dongtan_layout.html"></include>
					<hr />
				</div>
			</div>
		</div>
	</div>
	
	<div user-login>
		<form role="form" callback="create" validate>
			<div style="position: relative;height:50px;">
				<span style="float: left;width: 80%;">
					<textarea class="form-control" style="width: 100%; height: 50px;" 
						name="content" rule="required;length[5~200]" ng-model="dongtan.content" placeholder="今天你动弹了吗?"></textarea>
				</span>
				<span style="float: left;">
					<button type="submit" class="btn btn-success" style="height: 50px;">
						动弹
					</button>
				</span>
			</div>
		</form>
	</div>
</div>